package com.cloud.mall.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

import javax.validation.constraints.Size;
import java.util.Date;

/**
 * 商品sku属性表
 */
@Data
@TableName(value = "t_sku_attribute")
public class SkuAttribute {
    /**
     * id
     */
    @TableId(value = "id")
    private Long id;

    /**
     * sku_id
     */
    @TableField(value = "sku_id")
    private Long skuId;

    /**
     * 属性id
     */
    @TableField(value = "attribute_id")
    private Long attributeId;

    /**
     * 属性值
     */
    @Size(min = 0, max = 55 , message ="长度必须在{min}和{max}之间")
    @TableField(value = "attribute_value")
    private String attributeValue;

    /**
     * 0-无效，1-有效
     */
    @TableField(value = "status")
    private Byte status;

    /**
     * 创建时间
     */
    @TableField(value = "created_time")
    private Date createdTime;

    /**
     * 
     */
    @TableField(value = "created_by")
    private Long createdBy;

    /**
     * 
     */
    @TableField(value = "gmt_modified")
    private Date gmtModified;

    /**
     * 
     */
    @TableField(value = "modified_by")
    private Long modifiedBy;

}